// PartGenerator.h: interface for the PartGenerator class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_PARTGENERATOR_H__36703CD7_BAB5_49F5_AFD4_92534B28D5C4__INCLUDED_)
#define AFX_PARTGENERATOR_H__36703CD7_BAB5_49F5_AFD4_92534B28D5C4__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

class Part;

#include "singleton.h"
#include <gemat3d.h>
#include "RecordsetPtrWrap.h"
#include "ProjectSubObject.h"

namespace VersionControl
{
	class AFX_EXT_CLASS PartGenerator : public ProjectSubObject  
	{
		DECLARE_SINGLETON(PartGenerator)
	public:
		PartGenerator();
		virtual ~PartGenerator();
		
	public:
		Part* Generate(const CString& strCustomID, const CString& strStandardID);
		Part* Generate();
		Part* Generate(DAWrapper::RecordsetPtrWrap& rs);
		Part* Generate(Part* pPart);

	private:
		AcGeMatrix3d GetPartMatrix(DAWrapper::RecordsetPtrWrap& rs);
		void GetPartProperty(Part* pPart, DAWrapper::RecordsetPtrWrap& partrs);
	};
}
using namespace VersionControl;
AFX_EXT_API VersionControl::PartGenerator& GetPartGenerator();
#endif // !defined(AFX_PARTGENERATOR_H__36703CD7_BAB5_49F5_AFD4_92534B28D5C4__INCLUDED_)
